package com.bmps.springcloud.insuredmicroservice.model.trail.request;

import org.apache.commons.lang3.builder.EqualsBuilder;
import org.apache.commons.lang3.builder.HashCodeBuilder;

import java.io.Serializable;

/**
 * @Author :  zlc
 * @Date : 2019/9/10 11:07
 **/
public class TrailProductInfoModel implements Serializable {

    private String newPayMode;

    private String payMode;

    private Double sumPremL;

    private Double payPremL;

    private String payIntv;

    private String bonusGetMode;

    private String rnewFlag;

    private Integer getYear;

    private String getDutyKind;

    private String getYears;

    private String getDutyKindMQ;

    private String getYearsMQ;

    private String autoPayFlag;

    private TrailProductsModel products;

    public String getNewPayMode() {
        return newPayMode;
    }

    public void setNewPayMode(String newPayMode) {
        this.newPayMode = newPayMode;
    }

    public String getPayMode() {
        return payMode;
    }

    public void setPayMode(String payMode) {
        this.payMode = payMode;
    }

    public Double getSumPremL() {
        return sumPremL;
    }

    public void setSumPremL(Double sumPremL) {
        this.sumPremL = sumPremL;
    }

    public Double getPayPremL() {
        return payPremL;
    }

    public void setPayPremL(Double payPremL) {
        this.payPremL = payPremL;
    }

    public String getPayIntv() {
        return payIntv;
    }

    public void setPayIntv(String payIntv) {
        this.payIntv = payIntv;
    }

    public String getBonusGetMode() {
        return bonusGetMode;
    }

    public void setBonusGetMode(String bonusGetMode) {
        this.bonusGetMode = bonusGetMode;
    }

    public String getRnewFlag() {
        return rnewFlag;
    }

    public void setRnewFlag(String rnewFlag) {
        this.rnewFlag = rnewFlag;
    }

    public Integer getGetYear() {
        return getYear;
    }

    public void setGetYear(Integer getYear) {
        this.getYear = getYear;
    }

    public String getGetDutyKind() {
        return getDutyKind;
    }

    public void setGetDutyKind(String getDutyKind) {
        this.getDutyKind = getDutyKind;
    }

    public String getGetYears() {
        return getYears;
    }

    public void setGetYears(String getYears) {
        this.getYears = getYears;
    }

    public String getGetDutyKindMQ() {
        return getDutyKindMQ;
    }

    public void setGetDutyKindMQ(String getDutyKindMQ) {
        this.getDutyKindMQ = getDutyKindMQ;
    }

    public String getGetYearsMQ() {
        return getYearsMQ;
    }

    public void setGetYearsMQ(String getYearsMQ) {
        this.getYearsMQ = getYearsMQ;
    }

    public String getAutoPayFlag() {
        return autoPayFlag;
    }

    public void setAutoPayFlag(String autoPayFlag) {
        this.autoPayFlag = autoPayFlag;
    }

    public TrailProductsModel getProducts() {
        return products;
    }

    public void setProducts(TrailProductsModel products) {
        this.products = products;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) {return true;}

        if (o == null || getClass() != o.getClass()) {return false;}

        TrailProductInfoModel that = (TrailProductInfoModel) o;

        return new EqualsBuilder()
                .append(newPayMode, that.newPayMode)
                .append(payMode, that.payMode)
                .append(sumPremL, that.sumPremL)
                .append(payPremL, that.payPremL)
                .append(payIntv, that.payIntv)
                .append(bonusGetMode, that.bonusGetMode)
                .append(rnewFlag, that.rnewFlag)
                .append(getYear, that.getYear)
                .append(getDutyKind, that.getDutyKind)
                .append(getYears, that.getYears)
                .append(getDutyKindMQ, that.getDutyKindMQ)
                .append(getYearsMQ, that.getYearsMQ)
                .append(autoPayFlag, that.autoPayFlag)
                .append(products, that.products)
                .isEquals();
    }

    @Override
    public int hashCode() {
        return new HashCodeBuilder(17, 37)
                .append(newPayMode)
                .append(payMode)
                .append(sumPremL)
                .append(payPremL)
                .append(payIntv)
                .append(bonusGetMode)
                .append(rnewFlag)
                .append(getYear)
                .append(getDutyKind)
                .append(getYears)
                .append(getDutyKindMQ)
                .append(getYearsMQ)
                .append(autoPayFlag)
                .append(products)
                .toHashCode();
    }

    @Override
    public String toString() {
        return "TrailProductInfoModel{" +
                "newPayMode='" + newPayMode + '\'' +
                ", payMode='" + payMode + '\'' +
                ", sumPremL=" + sumPremL +
                ", payPremL=" + payPremL +
                ", payIntv='" + payIntv + '\'' +
                ", bonusGetMode='" + bonusGetMode + '\'' +
                ", rnewFlag='" + rnewFlag + '\'' +
                ", getYear=" + getYear +
                ", getDutyKind='" + getDutyKind + '\'' +
                ", getYears='" + getYears + '\'' +
                ", getDutyKindMQ='" + getDutyKindMQ + '\'' +
                ", getYearsMQ='" + getYearsMQ + '\'' +
                ", autoPayFlag='" + autoPayFlag + '\'' +
                ", products=" + products +
                '}';
    }
}
